<template>
  <div>
    <h2>这里是用户标题</h2>
    <p>这里是用户的内容，嘿嘿嘿</p>
    <p>用户id：{{$route.params.userId}}</p>
    <p>用户id：{{userId}}</p>
  </div>
</template>

<script>
  export default {
    name: "user",
    computed:{
      userId(){
        return this.$route.params.userId
      }
    },
    created() {
      console.log('user created');
    },
    destroyed() {
      console.log('user destroyed');
    }
  }
</script>

<style scoped>

</style>
